﻿#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int main(void) {
	int m, n;
	printf("Enter m,n;");
	scanf("%d%d", &m, &n);
	while(m != n) {
		while(m > n)m = m - n;
		while(n > m)n = n - m;
	}
	printf("m=%d\n", m);
	return 0;
}